<?php echo $form->renderFormTag('#', array('id' => 'form', 'method' => "post", "class" => "form")) ?>
<?= $form->renderHiddenFields() ?>
<fieldset>
    <div class="widget">
        <div class="title"> <?= image_tag('icons/dark/stats.png', array("class" => "titleIcon")); ?><h6>Statement</h6></div>
        <div class="formRow">
            <div class="fluid">
                <span class="span3"><span class="formNote">Customer Name</span><?php echo $form['customer_id']->render(array('data-placeholder' => " - - Select - - ", 'style' => "width:100%;", 'class' => "chzn-select")); ?> </span>
                <span class="span3"><span class="formNote">Line</span><?php echo $form['line_id']->render(array('data-placeholder' => " - - Select - - ", 'style' => "width:100%;", 'class' => "chzn-select")); ?> </span>
                <span class="span3"><span class="formNote">From Date</span><?php echo $form['fromDate']->render(array('class' => 'datepicker', 'readonly' => 'readonly')); ?> </span>
                <span class="span3"><span class="formNote">To Date</span><?php echo $form['toDate']->render(array('class' => 'datepicker', 'readonly' => 'readonly')); ?> </span>

                <span class="span3"><label for="customer_id" generated="true" class="error"><?= $form['customer_id']->renderError(); ?></label></span>
                <span class="span3"><label for="line_id" generated="true" class="error"><?= $form['line_id']->renderError(); ?></label></span>
                <span class="span3"><label for="fromDate" generated="true" class="error"><?= $form['fromDate']->renderError(); ?></label></span>
                <span class="span3"><label for="toDate" generated="true" class="error"><?= $form['toDate']->renderError(); ?></label></span>
            </div>
            <div class="xs"><a class="wButton2 bluewB" style="margin-right: 28px;" title="" id="searchStatement" href="javascript:void(0);"><span>Search</span></a>
                            <a class="wButton2 greyishB" title="" id="resetStatement" href="javascript:void(0);"><span>Reset</span></a></div>
        </div>
        
        <div class="ressultDiv">
                <?php  if(isset($result)) include_partial('statementDetails',array('result'=>$result, 'oldBalance'=>$oldBalance)) ?>
        </div>
</fieldset>
</form>

